import axios from 'axios'
// 探索推荐列表信息
export function mendedList(params) {
  return new Promise((resolve, reject) => {
    axios
      .post('/ship-portal/exploreRecommended/getExploreRecommendedList', params)
      .then(res => resolve(res))
      .catch(err => reject(err))
  })
}
// 美食标签列表
export function labelType(params) {
  return new Promise((resolve, reject) => {
    axios
      .post('/ship-portal/web/exploreType/getExploreLabelType', params)
      .then(res => resolve(res))
      .catch(err => reject(err))
  })
}
// 美食列表
export function deliciousList([]) {
  return new Promise((resolve, reject) => {
    axios
      .post('/ship-portal/restaurant/getRestaurant', [])
      .then(res => resolve(res))
      .catch(err => reject(err))
  })
}

// 美食详情
export function deliciousDetail(params) {
  return new Promise((resolve, reject) => {
    axios
      .post(
        '/ship-portal/restaurant/getRestaurantInfo?restaurantId=' +
          params.restaurantId
      )
      .then(res => resolve(res))
      .catch(err => reject(err))
  })
}

// 娱乐列表
export function getBarList() {
  return new Promise((resolve, reject) => {
    axios
      .post('/ship-portal/webExploreBar/getBarList')
      .then(res => resolve(res))
      .catch(err => reject(err))
  })
}

// 娱乐详情
export function getBarDetail(params) {
  return new Promise((resolve, reject) => {
    axios
      .post('/ship-portal/webExploreBar/getBarListInfo?barId=' + params.barId)
      .then(res => resolve(res))
      .catch(err => reject(err))
  })
}

// 购物列表
export function getDfsList() {
  return new Promise((resolve, reject) => {
    axios
      .post('/ship-portal/webExploreDfs/getDfsList')
      .then(res => resolve(res))
      .catch(err => reject(err))
  })
}

// 购物详情
export function getDfsListInfo(params) {
  return new Promise((resolve, reject) => {
    axios
      .post('/ship-portal/webExploreDfs/getDfsListInfo?dfsId=' + params.dfsId)
      .then(res => resolve(res))
      .catch(err => reject(err))
  })
}

// 演出列表
export function performList() {
  return new Promise((resolve, reject) => {
    axios
      .post('/ship-portal/Performance/getPerformance')
      .then(res => resolve(res))
      .catch(err => reject(err))
  })
}

// 演出详情
export function performDetail(params) {
  return new Promise((resolve, reject) => {
    axios
      .post(
        '/ship-portal/Performance/getPerformanceInfo?performanceId=' +
          params.performanceId
      )
      .then(res => resolve(res))
      .catch(err => reject(err))
  })
}
